package com.frejoys.dao.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.frejoys.dao.entity.UserLevelAgent;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

public interface UserLevelAgentMapper extends BaseMapper<UserLevelAgent> {

    //查找推广者父级id
    @Select("select user_id from j_user_level_agent where child_user_id = #{childId}")
    Long getParentId(@Param("childId") Long childId);
}
